<?php
/**
 * Created by PhpStorm.
 * User: BlueIdeaLirui
 * Date: 2020/2/27
 * Time: 11:35
 */

namespace common\utils;

use common\cache\CacheManager;

class ScoreUtils
{
    /**
     * 通过分值项获取分值
     * @param $item
     * @return object
     */
    public static function get($item)
    {
        return CacheManager::get($item);
    }

    /**
     * 设置分值
     * @param $item
     * @param $core
     * @param int $duration
     * @return bool
     */
    public static function set($item, $core, $duration = 0)
    {
        return CacheManager::set($item, $core, $duration);
    }

    /**
     * 删除分值项
     * @param $item
     * @return bool
     */
    public static function delete($item)
    {
        return CacheManager::delete($item);
    }
}
